package com.hailiang.study.javase.java.util;

import org.junit.Test;

import java.util.Arrays;
import java.util.List;

public class Arrays_asList {
    @Test
    public void test_asList() {
        String[] original = new String[] {"hello", "world", "java", "!!"};

        // 数组转换成List
        List<String> list = Arrays.asList(original);
        
        System.out.println(list.toString()); //执行的是ArrayList.toString方法
    }
}
